<?php
namespace StarCloud\Library;

class Redis extends \Redis
{
    const TIMEOUT = 3;

    public function __construct($host, $port, $password = '')
    {
        parent::__construct();

        $this->connect($host, $port, self::TIMEOUT);

        if (!empty($password)) {
            $this->auth($password);
        }
    }
}
